# This file should contain all the record creation needed to seed the database with its default values.
# The data can then be loaded with the rails db:seed command (or created alongside the database with db:setup).
#
# Examples:
#
#   movies = Movie.create([{ name: 'Star Wars' }, { name: 'Lord of the Rings' }])
#   Character.create(name: 'Luke', movie: movies.first)

# User.create!(username:'111',password:'111')


100.times do |i|
  Employee.create!(emp_code: "20230700#{i}", emp_name_cn: "taylor#{i}")
end

100.times do |i|
  Company.create!(name: "RCC分公司-#{i}", phone_no: "18616588654", postal_code: "02100", address: "上海", followup_employee_code: "20230700#{i}")
end

50.times do |i|
  Contact.create!(name: "联系人#{i}", companies_id: i+1, tel_no: '18616588654')
end

40.times do |i|
  FollowupRecord.create!(companies_id: i+1, contacts_id: i+1, note: "备注#{i}", followup_phase: "P001", followup_status: 0)
end